import { User } from 'src/modules/system/user/entities/user.entity';
import { Entity, PrimaryGeneratedColumn, Column, OneToOne, ManyToOne, OneToMany, ManyToMany, JoinTable } from 'typeorm';
@Entity('company')
export class Company {
    @PrimaryGeneratedColumn('uuid')
    Id: string;
    @Column()
    PId: string; // 父级Id
    @Column()
    Name: string; // 公司名称
    @Column()
    Level: string; // 公司级别
    @Column({default: 0})
    Deleted: number; // 删除标志，1为未删除，0为已删除
    @OneToMany(() => User, user => user.Company)
    Users: User[]; // 公司下的用户列表
}
